package org.springframework.samples.mvc.basic.sluzba;

import org.springframework.samples.mvc.basic.business.Transformer;

import com.proba.annotations.pojo.Sluzba;

public class SluzbaTransformer implements Transformer<Sluzba, SluzbaView> {

	@Override
	public SluzbaView transform(Sluzba entity) {
		SluzbaView view = new SluzbaView();
		view.setId(entity.getId());
		view.setInvestitor(entity.getInvestitor());
		return view;
	}

	@Override
	public Sluzba transform(SluzbaView view) {
		Sluzba entity = new Sluzba();
		entity.setId(view.getId());
		entity.setInvestitor(view.getInvestitor());
		return entity;
	}

}
